// @ts-check
/**
 * @type {import('vitepress').UserConfig}
 */
module.exports = {
  base: '/',
  title: '软考资料',
  lang: 'zh-CN',
  description: '软考备考网站，软考辅助网站',
  head: createHead(),
  themeConfig: {
    repo: 'vbenjs/vue-vben-admin',
    docsRepo: 'vbenjs/vue-vben-admin-doc',
    logo: '/logo6.png',
    docsBranch: 'main',
    editLinks: true,
    editLinkText: '为此页提供修改建议',
    nav: createNav(),
    sidebar: createSidebar(),
  },
};

/**
 * @type {()=>import('vitepress').HeadConfig[]}
 */

function createHead () {
  return [
    ['meta', { name: 'author', content: 'Vbenjs Team' }],
    [
      'meta',
      {
        name: 'keywords',
        content: 'vben, vitejs, vite, ant-design-vue, vue',
      },
    ],
    ['link', { rel: 'icon', type: 'image/svg+xml', href: '/logo.svg' }],
    [
      'meta',
      {
        name: 'viewport',
        content:
          'width=device-width,initial-scale=1,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no',
      },
    ],
    ['meta', { name: 'keywords', content: 'vue vben admin docs' }],
    ['link', { rel: 'icon', href: '/favicon.ico' }],
  ];
}

/**
 * @type {()=>import('./theme-default/config').DefaultTheme.NavItem[]}
 */
function createNav () {
  return [
    {
      text: '信息系统项目管理师',
      link: '/senior/',
      items: [
        {
          text: '目录',
          link: '/senior/xxxxxmgls/index',
        },
        {
          text: '第1章信息化和信息系统',
          link: '/senior/xxxxxmgls/01',
        },
        {
          text: '第2章信息系统项目管理基础',

          link: '/senior/xxxxxmgls/02',

        },
        {
          text: '第3章项目立项管理',

          link: '/senior/xxxxxmgls/03',

        }, {
          text: '第4章项目整体管理',

          link: '/senior/xxxxxmgls/04',

        }, {
          text: '第5章项目范围管理',

          link: '/senior/xxxxxmgls/05',

        }, {
          text: '第6章项目进度管理',

          link: '/senior/xxxxxmgls/06',

        }, {
          text: '第7章项目成本管理',

          link: '/senior/xxxxxmgls/07',

        }, {
          text: '第8章项目质量管理',

          link: '/senior/xxxxxmgls/08',

        }, {
          text: '第9章项目人力资源管理',

          link: '/senior/xxxxxmgls/09',

        }, {
          text: '第10章项目沟通管理和干系人管理',

          link: '/senior/xxxxxmgls/10',

        }, {
          text: '第11章项目风险管理',

          link: '/senior/xxxxxmgls/11',

        }, {
          text: '第12章项目采购管理',

          link: '/senior/xxxxxmgls/12',

        }, {
          text: '第13章项目合同管理',

          link: '/senior/xxxxxmgls/13',

        }, {
          text: '第14章信息文档管理与配置管理',

          link: '/senior/xxxxxmgls/14',

        }, {
          text: '第15章知识管理',

          link: '/senior/xxxxxmgls/15',

        }, {
          text: '第16章项目变更管理',

          link: '/senior/xxxxxmgls/16',

        }, {
          text: '第17章战略管理',

          link: '/senior/xxxxxmgls/17',

        }, {
          text: '第18章组织级项目管理',

          link: '/senior/xxxxxmgls/18',

        }, {
          text: '第19章流程管理',

          link: '/senior/xxxxxmgls/19',

        }, {
          text: '第20章项目集管理',

          link: '/senior/xxxxxmgls/20',

        }, {
          text: '第21章项目组合管理',

          link: '/senior/xxxxxmgls/21',

        }, {
          text: '第22章信息系统安全管理',

          link: '/senior/xxxxxmgls/22',

        }, {
          text: '第23章信息系统综合测试与管理',

          link: '/senior/xxxxxmgls/23',

        }, {
          text: '第24章项目管理成熟度模型',

          link: '/senior/xxxxxmgls/24',

        }, {
          text: '第25章量化的项目管理',

          link: '/senior/xxxxxmgls/25',

        }, {
          text: '第26章知识产权（法律法规）与标准规范',

          link: '/senior/xxxxxmgls/26',

        }, {
          text: '第27章管理科学基础知识',

          link: '/senior/xxxxxmgls/27',

        }, {
          text: '信息系统项目管理师',

          link: '/senior/xxxxxmgls/28',

        },  {
          text: '英文专题',

          link: '/senior/xxxxxmgls/29',

        }, {
          text: '职业道德',

          link: '/senior/xxxxxmgls/30',

        }
      ],
    },
    {
      text: '英文专题',
      link: '/english/',
      items: [
        {
          text: '补充章节: 英文专题',
          link: '/senior/xxxxxmgls/29',
        },
      ],
    },
    // {
    //   text: '中级',
    //   link: '/intermediate/',
    //   items: [
    //     {
    //       text: '指南',
    //       link: '/guide/introduction',
    //     },
    //     {
    //       text: '深入',
    //       link: '/dep/icon',
    //     },
    //     {
    //       text: '其他',
    //       link: '/other/faq',
    //     },
    //   ],
    // },
    // {
    //   text: '高级',
    //   link: '/senior/',
    //   items: [
    //     {
    //       text: '指南',
    //       link: '/guide/introduction',
    //     },
    //     {
    //       text: '深入',
    //       link: '/dep/icon',
    //     },
    //     {
    //       text: '其他',
    //       link: '/other/faq',
    //     },
    //   ],
    // },
    {
      text: '法律法规',
      link: '/regulations/',
      items: [
        {
          text: '目录',
          link: '/regulations/index',
        },
        {
          text: '中华人民共和国合同法',
          link: '/regulations/china_hetong',
        },
        {
          text: '中华人民共和国商标法',
          link: '/regulations/china_shangbiao',
        },
        {
          text: '计算机软件保护条例',
          link: '/regulations/china_jisuanjibaohutiaoli',
        },
        {
          text: '中华人民共和国著作权法',
          link: '/regulations/china_zhuzuoquan',
        },
        {
          text: '中华人民共和国招标投标法实施条例',
          link: '/regulations/china_zhaotoubiao',
        },
        {
          text: '中华人民共和国政府采购法实施条例',
          link: '/regulations/china_zhengfucaigou',
        },
        {
          text: '全国计算机技术与软件专业技术资格（水平）考试考场规则（笔试）（2018年10月修订）',
          link: '/regulations/china_kaochangguize',
        },
      ],
    },
    {
      text: '归纳背书',
      link: '/guinabeishu/',
      items: [
        {
          text: '信息系统项目管理师',
          link: '/senior/xxxxxmgls/28',
        },
      ],
    },
    // {
    //   text: '组件',
    //   link: '/components/',
    //   items: [
    //     {
    //       text: '介绍',
    //       link: '/components/introduction',
    //     },
    //     {
    //       text: '全局组件',
    //       link: '/components/glob/button',
    //     },
    //     {
    //       text: '常用组件',
    //       link: '/components/basic',
    //     },
    //     {
    //       text: '函数式组件',
    //       link: '/components/functional/context-menu',
    //     },
    //   ],
    // },
    // {
    //   text: '相关链接',
    //   items: [
    //     {
    //       text: 'Discord Chat',
    //       link: 'https://discord.gg/8GuAdwDhj6',
    //     },
    //     {
    //       text: '完整版预览',
    //       link: 'https://vvbin.cn/next',
    //     },
    //     {
    //       text: '完整版源码',
    //       link: 'https://github.com/vbenjs/vue-vben-admin',
    //     },
    //     {
    //       text: '精简版预览',
    //       link: 'https://vvbin.cn/thin/next',
    //     },
    //     {
    //       text: '精简版源码',
    //       link: 'https://github.com/vbenjs/vben-admin-thin-next',
    //     },
    //     {
    //       text: '文档源码',
    //       link: 'https://github.com/vbenjs/vue-vben-admin-doc',
    //     },
    //     {
    //       text: '更新日志',
    //       link: 'https://github.com/vbenjs/vue-vben-admin/blob/main/CHANGELOG.md',
    //     },
    //   ],
    // },
    // {
    //   text: '赞助',
    //   link: '/other/donate',
    // },
  ];
}

function createSidebar () {
  return {
    '/senior': [
      {
        text: '信息系统项目管理师',
        children: [
          {
            text: '目录',
            link: '/senior/xxxxxmgls/index',
          },
          {
            text: '第1章信息化和信息系统',
            link: '/senior/xxxxxmgls/01',
          },
          {
            text: '第2章信息系统项目管理基础',

            link: '/senior/xxxxxmgls/02',

          },
          {
            text: '第3章项目立项管理',

            link: '/senior/xxxxxmgls/03',

          }, {
            text: '第4章项目整体管理',

            link: '/senior/xxxxxmgls/04',

          }, {
            text: '第5章项目范围管理',

            link: '/senior/xxxxxmgls/05',

          }, {
            text: '第6章项目进度管理',

            link: '/senior/xxxxxmgls/06',

          }, {
            text: '第7章项目成本管理',

            link: '/senior/xxxxxmgls/07',

          }, {
            text: '第8章项目质量管理',

            link: '/senior/xxxxxmgls/08',

          }, {
            text: '第9章项目人力资源管理',

            link: '/senior/xxxxxmgls/09',

          }, {
            text: '第10章项目沟通管理和干系人管理',

            link: '/senior/xxxxxmgls/10',

          }, {
            text: '第11章项目风险管理',

            link: '/senior/xxxxxmgls/11',

          }, {
            text: '第12章项目采购管理',

            link: '/senior/xxxxxmgls/12',

          }, {
            text: '第13章项目合同管理',

            link: '/senior/xxxxxmgls/13',

          }, {
            text: '第14章信息文档管理与配置管理',

            link: '/senior/xxxxxmgls/14',

          }, {
            text: '第15章知识管理',

            link: '/senior/xxxxxmgls/15',

          }, {
            text: '第16章项目变更管理',

            link: '/senior/xxxxxmgls/16',

          }, {
            text: '第17章战略管理',

            link: '/senior/xxxxxmgls/17',

          }, {
            text: '第18章组织级项目管理',

            link: '/senior/xxxxxmgls/18',

          }, {
            text: '第19章流程管理',

            link: '/senior/xxxxxmgls/19',

          }, {
            text: '第20章项目集管理',

            link: '/senior/xxxxxmgls/20',

          }, {
            text: '第21章项目组合管理',

            link: '/senior/xxxxxmgls/21',

          }, {
            text: '第22章信息系统安全管理',

            link: '/senior/xxxxxmgls/22',

          }, {
            text: '第23章信息系统综合测试与管理',

            link: '/senior/xxxxxmgls/23',

          }, {
            text: '第24章项目管理成熟度模型',

            link: '/senior/xxxxxmgls/24',

          }, {
            text: '第25章量化的项目管理',

            link: '/senior/xxxxxmgls/25',

          }, {
            text: '第26章知识产权（法律法规）与标准规范',

            link: '/senior/xxxxxmgls/26',

          }, {
            text: '第27章管理科学基础知识',

            link: '/senior/xxxxxmgls/27',

          }, {
            text: '信息系统项目管理师',

            link: '/senior/xxxxxmgls/28',

          }, {
            text: '英文专题',

            link: '/senior/xxxxxmgls/29',

          }, {
            text: '职业道德',

            link: '/senior/xxxxxmgls/30',

          }
        ],
      },
    ],
    '/regulations/': [
      {
        text: '法律法规',
        children: [
          {
            text: '前言',
            link: '/regulations/index',
          },
          {
            text: '合同法',
            link: '/regulations/china_hetong',
          },
          {
            text: '商标法',
            link: '/regulations/china_shangbiao',
          },
          {
            text: '计算机软件保护条例',
            link: '/regulations/china_jisuanjibaohutiaoli',
          },
          {
            text: '中华人民共和国著作权法',
            link: '/regulations/china_zhuzuoquan',
          },
          {
            text: '中华人民共和国招标投标法实施条例',
            link: '/regulations/china_zhaotoubiao',
          },
          {
            text: '中华人民共和国政府采购法实施条例',
            link: '/regulations/china_zhengfucaigou',
          },
          {
            text: '全国计算机技术与软件专业技术资格（水平）考试考场规则（笔试）（2018年10月修订）',
            link: '/regulations/china_kaochangguize',
          },
        ],
      },
 
    ],
    '/': [
      {
        text: '信息系统项目管理师',
        children: [
          {
            text: '目录',
            link: '/senior/xxxxxmgls/index',
          },
          {
            text: '第1章信息化和信息系统',
            link: '/senior/xxxxxmgls/01',
          },
          {
            text: '第2章信息系统项目管理基础',

            link: '/senior/xxxxxmgls/02',

          },
          {
            text: '第3章项目立项管理',

            link: '/senior/xxxxxmgls/03',

          }, {
            text: '第4章项目整体管理',

            link: '/senior/xxxxxmgls/04',

          }, {
            text: '第5章项目范围管理',

            link: '/senior/xxxxxmgls/05',

          }, {
            text: '第6章项目进度管理',

            link: '/senior/xxxxxmgls/06',

          }, {
            text: '第7章项目成本管理',

            link: '/senior/xxxxxmgls/07',

          }, {
            text: '第8章项目质量管理',

            link: '/senior/xxxxxmgls/08',

          }, {
            text: '第9章项目人力资源管理',

            link: '/senior/xxxxxmgls/09',

          }, {
            text: '第10章项目沟通管理和干系人管理',

            link: '/senior/xxxxxmgls/10',

          }, {
            text: '第11章项目风险管理',

            link: '/senior/xxxxxmgls/11',

          }, {
            text: '第12章项目采购管理',

            link: '/senior/xxxxxmgls/12',

          }, {
            text: '第13章项目合同管理',

            link: '/senior/xxxxxmgls/13',

          }, {
            text: '第14章信息文档管理与配置管理',

            link: '/senior/xxxxxmgls/14',

          }, {
            text: '第15章知识管理',

            link: '/senior/xxxxxmgls/15',

          }, {
            text: '第16章项目变更管理',

            link: '/senior/xxxxxmgls/16',

          }, {
            text: '第17章战略管理',

            link: '/senior/xxxxxmgls/17',

          }, {
            text: '第18章组织级项目管理',

            link: '/senior/xxxxxmgls/18',

          }, {
            text: '第19章流程管理',

            link: '/senior/xxxxxmgls/19',

          }, {
            text: '第20章项目集管理',

            link: '/senior/xxxxxmgls/20',

          }, {
            text: '第21章项目组合管理',

            link: '/senior/xxxxxmgls/21',

          }, {
            text: '第22章信息系统安全管理',

            link: '/senior/xxxxxmgls/22',

          }, {
            text: '第23章信息系统综合测试与管理',

            link: '/senior/xxxxxmgls/23',

          }, {
            text: '第24章项目管理成熟度模型',

            link: '/senior/xxxxxmgls/24',

          }, {
            text: '第25章量化的项目管理',

            link: '/senior/xxxxxmgls/25',

          }, {
            text: '第26章知识产权（法律法规）与标准规范',

            link: '/senior/xxxxxmgls/26',

          }, {
            text: '第27章管理科学基础知识',

            link: '/senior/xxxxxmgls/27',

          }, {
            text: '信息系统项目管理师',

            link: '/senior/xxxxxmgls/28',

          }, {
            text: '英文专题',

            link: '/senior/xxxxxmgls/29',

          }, {
            text: '职业道德',

            link: '/senior/xxxxxmgls/30',

          }
        ],
      },
    ],
  };
}

// /**
//  * @type {(namespace:string,items:string[])=>string[]}
//  */
// function urlWrapper(namespace, items) {
//   return items.map((item) => namespace + item);
// }

// function getGuildNav() {
//   return urlWrapper('/guide', ['/']);
// }
